﻿using System;
using System.Collections.Generic;
using System.Data.SqlClient;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace TAO_FORM_GHI
{
    class DAL
    {
        public DAL()
        {}
        
            public void  InsertCustomers (int id, string name)
             {
                SqlConnection co = new SqlConnection();
                co.ConnectionString=@"Data Source=QUYNHUYEN\SQLEXPRESS;Initial Catalog=sale; User Id=sa; Password=sa";                 
                co.Open();
                SqlCommand cmd = new SqlCommand("insert into customers values ("+id.ToString() +",'"+name+ "')" , co);
                cmd.ExecuteNonQuery();
                co.Close();
            }
    }
 }